package com.landinfo.service.dto;


import java.time.ZonedDateTime;
import java.io.Serializable;
import java.util.Objects;

/**
 * A DTO for the PatrolRecord entity.
 */
public class PatrolRecordDTO implements Serializable {

    private Long id;

    private String patrolDevice;

    private String patrolPerson;

    private String patrolStyle;

    private String patrolPath;

    private ZonedDateTime startDate;

    private String endDate;

    private String remark;

    private Double patrolDistance;

    private ZonedDateTime createDate;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getPatrolDevice() {
        return patrolDevice;
    }

    public void setPatrolDevice(String patrolDevice) {
        this.patrolDevice = patrolDevice;
    }

    public String getPatrolPerson() {
        return patrolPerson;
    }

    public void setPatrolPerson(String patrolPerson) {
        this.patrolPerson = patrolPerson;
    }

    public String getPatrolStyle() {
        return patrolStyle;
    }

    public void setPatrolStyle(String patrolStyle) {
        this.patrolStyle = patrolStyle;
    }

    public String getPatrolPath() {
        return patrolPath;
    }

    public void setPatrolPath(String patrolPath) {
        this.patrolPath = patrolPath;
    }

    public ZonedDateTime getStartDate() {
        return startDate;
    }

    public void setStartDate(ZonedDateTime startDate) {
        this.startDate = startDate;
    }

    public String getEndDate() {
        return endDate;
    }

    public void setEndDate(String endDate) {
        this.endDate = endDate;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Double getPatrolDistance() {
        return patrolDistance;
    }

    public void setPatrolDistance(Double patrolDistance) {
        this.patrolDistance = patrolDistance;
    }

    public ZonedDateTime getCreateDate() {
        return createDate;
    }

    public void setCreateDate(ZonedDateTime createDate) {
        this.createDate = createDate;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        PatrolRecordDTO patrolRecordDTO = (PatrolRecordDTO) o;
        if(patrolRecordDTO.getId() == null || getId() == null) {
            return false;
        }
        return Objects.equals(getId(), patrolRecordDTO.getId());
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(getId());
    }

    @Override
    public String toString() {
        return "PatrolRecordDTO{" +
            "id=" + getId() +
            ", patrolDevice='" + getPatrolDevice() + "'" +
            ", patrolPerson='" + getPatrolPerson() + "'" +
            ", patrolStyle='" + getPatrolStyle() + "'" +
            ", patrolPath='" + getPatrolPath() + "'" +
            ", startDate='" + getStartDate() + "'" +
            ", endDate='" + getEndDate() + "'" +
            ", remark='" + getRemark() + "'" +
            ", patrolDistance='" + getPatrolDistance() + "'" +
            ", createDate='" + getCreateDate() + "'" +
            "}";
    }
}
